<!DOCTYPE html>
<html lang="zh-CN">

<head>
  <meta charset="UTF-8">
  <meta name="viewport" content="width=device-width, initial-scale=1.0">
  <title>Document</title>
  <style>
    /* 第 3 个 li */
    ul>li:nth-of-type(3) {
      color: red;
    }
  </style>
</head>

<body>
  <ul>
    <li>li</li>
    <p>p</p>
    <li>li 2</li>
    <p>p 2</p>
    <li>li 3</li>
    <p>p 3</p>
    <li>li 4</li>
    <p>p 4</p>
  </ul>
</body>

</html>